﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true"
    CodeBehind="RoomOder.aspx.cs" Inherits="HAINGUYEN_HOTEL.RoomOder" %>

<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
    <style type="text/css">
        .style8
        {
        }
        .style9
        {
            width: 188px;
        }
    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <div class="sevice">
        <asp:UpdatePanel runat="server" ID="upInfor" UpdateMode="Conditional">
            <ContentTemplate>
                <div id="divhaveroom" runat="server">
                    <table class="product-table" style="width: 910px">
                        <tr>
                            <td class="style9">
                                Họ tên người đặt
                            </td>
                            <td>
                                <asp:TextBox ID="txtTenKH" runat="server"></asp:TextBox>
                            </td>
                        </tr>
                        <tr>
                            <td class="style9">
                                Số CMND( Passport)
                            </td>
                            <td>
                                <asp:TextBox ID="txtCMND" runat="server"></asp:TextBox>
                            </td>
                        </tr>
                        <tr>
                            <td class="style9">
                                Ngày đến
                            </td>
                            <td>
                                <asp:TextBox CssClass="datepicker" ID="txtNgayDen" runat="server"></asp:TextBox>
                            </td>
                        </tr>
                        <tr>
                            <td class="style9">
                                Ngày đi
                            </td>
                            <td>
                                <asp:TextBox ID="txtNgayDi" CssClass="datepicker" runat="server"></asp:TextBox>
                            </td>
                        </tr>
                        <tr>
                            <td colspan="2">
                                Chi tiết đặt phòng
                                <asp:Label ID="lbError" runat="server" Font-Bold="True" ForeColor="#CC3300"></asp:Label>
                            </td>
                        </tr>
                        <tr>
                            <td class="style8" colspan="2">
                                <asp:GridView ID="gvList" runat="server" Width="100%" OnRowCommand="gvList_RowCommand"
                                    OnRowDataBound="gvList_RowDataBound">
                                    <Columns>
                                        <asp:BoundField DataField="TenLoaiPhong" HeaderText="Loại phòng" />
                                        <asp:BoundField HeaderText="Hạng phòng" DataField="TenHangPhong" />
                                        <asp:TemplateField HeaderText="Số lượng phòng đặt">
                                            <ItemTemplate>
                                                <asp:TextBox runat="server" ID="txtSoLuong" Text='<%# Eval("SoLuong") %>' />
                                            </ItemTemplate>
                                            <ItemStyle HorizontalAlign="Center" />
                                        </asp:TemplateField>
                                        <asp:BoundField HeaderText="Số người" DataField="SoNguoi" />
                                        <asp:TemplateField HeaderText="Đơn giá">
                                            <ItemTemplate>
                                                <%# String.Format("{0:0,0}",decimal.Parse(Eval("Gia").ToString()))%>
                                            </ItemTemplate>
                                            <ItemStyle HorizontalAlign="Right" />
                                        </asp:TemplateField>
                                        <asp:TemplateField HeaderText="Thành tiền">
                                            <ItemTemplate>
                                                <%# String.Format("{0:0,0}", decimal.Parse(Eval("SoLuong").ToString()) * decimal.Parse(Eval("Gia").ToString()))%>
                                            </ItemTemplate>
                                            <ItemStyle HorizontalAlign="Right" />
                                        </asp:TemplateField>
                                        <asp:TemplateField HeaderText="Tùy chọn">
                                            <ItemTemplate>
                                                <asp:LinkButton runat="server" ID="linkDelete" CommandArgument='<%# Eval("MaLoaiPhong")+"-"+Eval("MaHangPhong")%>'
                                                    CommandName="DeleteItem" Text="Xóa" />
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                    </Columns>
                                </asp:GridView>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left">
                                <div class="item_box">
                                    <label>
                                        <input name="btype" type="radio" class="f_radio" value="paypal" checked="">
                                        <img src="http://image.ecplaza.net/global/trademall/common/img_paysytem.gif" alt="PayPal"
                                            class="vm"><img src="http://image.ecplaza.net/global/trademall/common/img_paycard.gif"
                                                alt="" class="vm"></label>
                                         
                                </div>
                                <div style="text-align:center">
                                <asp:Button ID="btnCheckOut" runat="server" Text="Check out" OnClick="btnCheckOut_Click" CssClass="primary" />
                                <asp:Button ID="btnPreview" runat="server" Text="Xem trước" OnClick="btnPreview_Click" CssClass="primary"/>
                                </div>
                            </td>
                            <td style="vertical-align: middle; text-align: right; padding-right:10px"> 
                                Tổng: <asp:Label ID="lbTongTien" runat="server" Text="Label" style="color:Red"></asp:Label> $vnd
                            </td>
                        </tr>
                    </table>
                </div>
                <div id="divhavenoroom" runat="server">
                    Bạn chưa đăt phòng nào trong khách sạn.</div>
            </ContentTemplate>
        </asp:UpdatePanel>
    </div>
</asp:Content>
